package net.wangds.auth.user.entity;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.NoArgsConstructor;
import net.wangds.auth.common.entity.AbstractResActionRef;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.UniqueConstraint;

@Entity
@Table(
        name="auth_user_res_ref",
        uniqueConstraints=@UniqueConstraint(columnNames={"userId","resId"})
)
@NoArgsConstructor(force = true)
@AllArgsConstructor
@Builder
public class GeneralUserResRef extends AbstractResActionRef {
    private static final long serialVersionUID = 0;
    /**
     * 角色id.
     */
    @Column(length=36)
    private String userId;

    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }
}
